import express from 'express'
import logController from '@/controllers/logController'

const router = express.Router()

/**
 * 查询日志列表
 * GET /logs
 */
router.get('/', logController.getLogs)

/**
 * 查询日志详情
 * GET /logs/:id
 */
router.get('/:id', logController.getLogInfo)

/**
 * 清空全部日志
 * DELETE /logs/clear
 */
router.delete('/clear', logController.clearLogs)

/**
 * 删除日志
 * DELETE /admin/logs/:id
 */
router.delete('/:id', logController.deleteLog)

export default router
